<template>
    <div>
      <el-row class="tac">
        <el-col  :span="24">
          <el-menu
            :default-active="$route.path"
            class="el-menu-vertical-demo"
            @open="handleOpen"
            @close="handleClose"
            background-color="#545c64"
            text-color="#fff"
            active-text-color="#ffd04b"
            router
            :router='true'>


            <el-submenu index="1">
              <template slot="title">
                <i class="el-icon-location"></i>
                <span>布局</span>
              </template>

              <el-menu-item-group>
                <template slot="title">分组一</template>
                <el-menu-item index="/layoutTest">Layout</el-menu-item>
                <el-menu-item index="/container">Container</el-menu-item>
              </el-menu-item-group>

              <el-menu-item-group title="分组二">
                <el-menu-item index="/buttonTest">按钮</el-menu-item>
              </el-menu-item-group>
              <el-menu-item-group title="分组三">
                <el-menu-item index="/formTest">表单form</el-menu-item>
              </el-menu-item-group>
              <el-menu-item-group title="分组四">
                <el-menu-item index="/tableTest">table</el-menu-item>
              </el-menu-item-group>
              <el-menu-item-group title="分组wu">
                <el-menu-item index="/tabTest">table</el-menu-item>
              </el-menu-item-group>

              <el-submenu index="1-4">
                <template slot="title">选项4</template>
                <el-menu-item index="1-4-1">选项1</el-menu-item>
              </el-submenu>

            </el-submenu>
          </el-menu>
        </el-col>
      </el-row>
    </div>
</template>

<script>
    export default {
        name: 'NavMenu',
        props: {},
        components: {},
        data() {
            return {}
        },
        computed: {

        },
        watch: {
            data(newValue, oldValue) {

            }
        },
        methods: {
          handleOpen(key, keyPath) {
            console.log(key, keyPath);
          },
          handleClose(key, keyPath) {
            console.log(key, keyPath);
          }
        },
        filters: {
            fnName: function (value) {
                return value
            }
        }
    }
</script>

<style scoped>

</style>
